import {Controller} from "../type/interfaces.ts";
import { handle } from "../vendor/handle.ts";
import {shell} from "electron";
import { WORKSPACE } from "../type/const.ts";
import {mainWindow} from "../windows/main-window.ts";


export default class HomeController implements Controller {
  @handle("showDevTool")
  showDevTool() {
    mainWindow.showDevTool()
  }

  @handle("openWorkspace")
  openWorkspace(){
    shell.openPath(WORKSPACE);
  }
}

export const homeController = new HomeController()
